package src.main.java.org.collection;

import java.util.ArrayList;
import java.util.Collection;

public class Test4 {
    public static void main(String[] args) {
        Collection<Movie> movies = new ArrayList<>();
        movies.add(new Movie("《肖生克的救赎》",9.6,"张三"));
        movies.add(new Movie("《抓娃娃》",8.3,"李四"));
        movies.add(new Movie("《一人之下》",9.5,"王五"));

        for (Movie movie:movies) {
            System.out.println(movie.getName());
            System.out.println(movie.getScore());
            System.out.println(movie.getDirector());
            System.out.println("==========");
        }
    }
}
